
#ifndef __CE_KEYBOARD_H__
#define __CE_KEYBOARD_H__

#include <cegfx/iqf.h>
#include <dinput.h>
#include <cegfx/ceexport.h>

class CE_GFX_API ceKeyboard : public iBase
{
	IQF_DECLARATION;
private:
	BYTE	keys[2][256];
	int idx0;
	int idx1;
	LPDIRECTINPUTDEVICE8	keyboardDevice;

public:
	ceKeyboard ();
	~ceKeyboard ();

	bool Initialize (LPDIRECTINPUT8 input);
	bool UpdateState ();

	virtual bool IsKeyDown (int key) const;
	virtual bool IsKeyUp (int key) const;
	virtual bool IsKeyPressed (int key) const;
	virtual bool IsKeyReleased (int key) const;
};



#endif /* ! __CE_KEYBOARD_H__ */ 
